package de.slowpoke.flattr.Utils
{
	/**
	 * Provides methods for string convertion.
	 * 
	 * @author Brian
	 * 
	 */
	public final class Convert
	{
		
		/**
		 * Converts a string into its hexadecimal representation.
		 * 
		 * @param input The string to convert
		 * @return converted string
		 */
		public static function bin2hex(input:String):String
		{
			var output:String;
			
			for(var x:int=0; x < input.split("").length; x++){
				output = output + input.charCodeAt(x).toString(16);
			}
			
			return output;
		}
		
	}
}